package com.simen.hellobytes.image;

public enum ImageMimeType {

    UNKNOWN(null, null),
    JPG("image/jpeg", "jpg"),
    JPEG("image/jpeg", "jpeg"),
    PNG("image/png", "png"),
    GIF("image/gif", "gif"),
    BMP("image/bmp", "bmp"),
    TIFF("image/tiff", "tiff"),
    TIFF2("image/tiff", "tiff2"),
    WEBP("image/webp", "webp");

    private String mimeType;
    private String ext;

    ImageMimeType(String mimeType, String ext) {
        this.mimeType = mimeType;
        this.ext = ext;
    }

    public String getMimeType() {
        return mimeType;
    }

    public String getExt() {
        return ext;
    }

    @Override
    public String toString() {
        return mimeType==null?"unkown":mimeType;
    }
}
